package com.the_ring.structural.composite;

/**
 * @author: t22306139
 * @date: 2023/12/1  10:27
 */
public class Leaf implements Component{

    private String name;

    public Leaf(String name) {
        this.name = name;
    }

    @Override
    public void operation() {
        System.out.println("树叶" + name + ": 被访问！");
    }
}
